import Vue from 'vue'
import Router from 'vue-router'
import Menu from '@/components/Menu'
import Hearder from '@/components/Hearder'
//课程管理
import CourseAdd from '@/components/Course/CourseAdd'
import CourseShow from '@/components/Course/CourseShow'
import CourseCheck from '@/components/Course/CourseCheck'
import CourseType from '@/components/Course/CourseType'
//用户管理
import Register from '@/components/User/Register'
import Login from '@/components/User/Login'
//订单管理Addtheorder
import Addtheorder from '@/components/Order/Addtheorder'
import Theorderlist from '@/components/Order/Theorderlist'
//题库分类
import Questionclassification from '@/components/Question/Questionclassification'
Vue.use(Router)

export default new Router({
  routes: [
    
    {
      path: '/Menu',
      name: 'Menu',
      component: Menu
    },
    {
      path: '/Questionclassification',
      name: 'Questionclassification',
      component: Questionclassification
    },
    {
      path: '/Addtheorder',
      name: 'Addtheorder',
      component: Addtheorder
    },
    {
      path: '/Theorderlist',
      name: 'Theorderlist',
      component: Theorderlist
    },
    {
      path: '/',
      redirect:'/Register'//重新定向redirect，首次加载
    },
    {
      path: '/Login',
      name: 'Login',
      component: Login
    },
    {
      path: '/CourseAdd',
      name: 'CourseAdd',
      component: CourseAdd
    },
    {
      path: '/Register',
      name: 'Register',
      component: Register
    },
    {
      path: '/Hearder',
      name: 'Hearder',
      component: Hearder
    },
    {
      path: '/CourseShow',
      name: 'CourseShow',
      component: CourseShow
    },
    {
      path: '/CourseCheck',
      name: 'CourseCheck',
      component: CourseCheck
    },
    {
      path: '/CourseType',
      name: 'CourseType',
      component: CourseType
    },
  ]
})
